The incident happened in Ulster County on Monday morning, May 16 at Ellenville Junior High School.
Ellenville Police say that when officers arrived, the student was no longer in possession of the knife and was "isolated in a room with building administration."
An investigation revealed the student brought the kitchen knife in his backpack into the school and intended to stab one of the staff members at the school, police said.
Police then immediately took the boy into custody and he was transported to Garnet Regional Hospital in Orange County, located in Middletown, for evaluation.
When he is released from the psychiatric unit, he will be facing criminal charges in Ulster County Family Court, police said.
"The actions that this student took could have ended very tragically," Ellenville PD Chief Philip Mattracion said. "Thanks to the quick-thinking actions of all involved, this incident ended without any injuries to any student, or staff member.
"Thankfully, there but for the grace of God, he was not able to execute his plan to fruition."
The boy's name was not released due to his status as a minor.
Click here to follow Daily Voice Tappan-Blauvelt and receive free news updates.